1. Field of the Invention
The present invention relates to a method of estimating a coded block pattern (CBP) and a method of determining a block mode using the same for use in a moving picture encoder, and more particularly, to a coded block pattern (CBP) estimating method which is performed using an average value and a dispersion value between blocks of CBPs in a moving picture encoder for IP-TVs (Internet Protocol-Televisions), and a block mode decision method of reducing the number of H.264 encoding operations as much as possible and avoiding a reduction in picture quality.
2. Description of the Related Art
Digital video data is used in video conference apparatuses, high-definition televisions, Video-On-Demand (VOD) receivers, personal computers (PCs) supporting Moving Picture Experts Group (MPEG) video signals, game machines, terrestrial digital broadcasting receivers, digital satellite broadcasting receivers, cable televisions (CATVs), etc. Since an amount of digital video data is increased due to features of the digital video data and during the conversion of analog signals into digital signals, the digital video data is not used as it is but is compressed using an efficient compression method.
Three types of methods of compressing digital video data are widely used. These include a method of reducing temporal redundancy, a method of reducing spatial redundancy, and a method of reducing an amount of data by using statistical characteristics of codes generated. One of the methods of reducing temporal redundancy is a motion estimation and compensation method, which is used in most moving picture compression standards such as MPEG series and H.263.
Although a motion estimation and compensation method which is used to determine the most similar portion between a previous or future reference frame and a particular portion on a current frame, and transmits only a difference component between the two portions can reduce data more effectively since the difference component to be transmitted is reduced as a motion vector is found as accurately as possible, a considerable amount of estimation time and calculation is required in order to determine the most similar portion from the previous or future frame. Thus, ongoing research is being conducted into ways of reducing a motion estimation time that is the most time consuming when encoding moving pictures.
Meanwhile, there are two main types of motion estimation method: a pixel-by-pixel basis estimation method and a block-by-block basis estimation method, the latter of which is a representative algorithm which is most widely used.
The block-by-block basis estimation method is a method of dividing an image into blocks of a predetermined magnitude and finding a block which best matches a current image block within a search region of a previous image. A difference between the found block and the current image block is called a motion vector. The block-by-block basis estimation method is used to encode the motion vector and process the encoded motion vector. To calculate a match between two blocks, various match functions can be used. The most generally used match function is a Sum of Absolute Difference (SAD) function which sums all absolute values of differences between pixels in two blocks.
In the case of the H.264 CODEC, a search is performed using a Cost function based on a Rate Distortion Optimization (RDO) function instead of an existing SAD based search method. That is, the Cost function which is used to perform a search in the H.264 CODEC is a Rate-Distortion (RD) based Cost function which sums an existing SAD value and a value which is obtained by multiplying the number of encoded coefficients by a Lagrange multiplier. Here, the number of the encoded coefficients is determined by being substituted by a value proportional to a quantization coefficient value, and a Cost value is determined by multiplying the determined number of the encoded coefficients by a fixed Lagrange multiplier. Based on the Cost value, a search is performed.
Also, an H.264 moving picture encoder does not perform an encoding operation on a 16-to-16 large block basis or an 8-to-8 large block basis as in an existing moving picture encoder, in order to obtain a high compression efficiency and a high quality of picture, but is configured to select a mode having a minimum value among respective blocks with eight kinds of respectively different block modes.
However, since various kinds of encoding operations should not only be independently performed for each block mode but also main pixels and sub-pixels should be searched, in order to determine eight kinds of respectively different block modes, the H.264 moving picture encoder is required to make a large number of calculations and requires a large amount of calculation time in comparison with an existing moving picture encoding algorithm. Therefore, if a number of operations for determination of a block mode is reduced to a minimum value, operation time can be reduced and deterioration of picture quality can be avoided. Accordingly, a moving picture encoder for IP-TVs can be implemented.
As conventional art, U.S. patent Publication No. 2003-633273 (Feb. 3, 2005), U.S. Pat. No. 6,628,845 (Sep. 30, 2003), Korean Patent Publication No. 01-75406 (Apr. 29, 2004), Korean Patent Publication No. 02-69129 (Oct. 16, 2000), and Korean Patent Publication No. 03-42350 (Jun. 27, 2003), have been disclosed, but do not teach a technology of estimating a CBP (Coded Block Pattern) value in advance and estimating and determining P and B block modes.